package com.windgo.mapper;

import com.windgo.bean.MarketRegion;
import com.windgo.bean.MarketRegionExample;
import com.windgo.bean.common.MarketRegionInfo;
import com.windgo.bean.regionvo.GranChildrenVo;
import com.windgo.bean.regionvo.RegionVo2;
import com.windgo.bean.regionvo.RegionVo3;
import com.windgo.bean.regionvo.RegionVo4;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface MarketRegionMapper {
    List<RegionVo4> selectByAllChildren(Integer id);
    List<RegionVo2> selectChildrenById(Integer id);
    List<RegionVo3> selectAllById(Integer id);
    List<GranChildrenVo> selectById(Integer id);
    long countByExample(MarketRegionExample example);

    int deleteByExample(MarketRegionExample example);

    int deleteByPrimaryKey(Integer id);//where id=#{id}

    int insert(MarketRegion row);

    int insertSelective(MarketRegion row);

    List<MarketRegion> selectByExample(MarketRegionExample example);

    MarketRegion selectByPrimaryKey(Integer id);

    int updateByExampleSelective(@Param("row") MarketRegion row, @Param("example") MarketRegionExample example);

    int updateByExample(@Param("row") MarketRegion row, @Param("example") MarketRegionExample example);

    int updateByPrimaryKeySelective(MarketRegion row);

    int updateByPrimaryKey(MarketRegion row);
    List<MarketRegionInfo> selectRegionInfo(MarketRegionExample example);
    List<MarketRegionInfo> selectChildrenRegionInfo(Integer id);
    List<GranChildrenVo> selectGranChildrenRegionInfo(Integer id);
}